package com.aabte.design2.structural.wrapper;

/**
 * @author Daniel
 * @version 1.0
 * @date 2020/5/3
 */
public class FileDataSource implements DataSource {

    private String data;

    @Override
    public void writeData(String data) {
        System.out.println(this.getClass().getSimpleName() + "#writeData, data = " + data);
        this.data = data;
    }

    @Override
    public String readData() {
        System.out.println(this.getClass().getSimpleName() + "#readData, data = " + data);
        return this.data;
    }
}
